﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;
using BizWeb.Models.Repository;

namespace BizWeb.Controllers
{

    [HandleError]
    public class HomeController : Controller
    {
        // Setup Repository
        PostRepository postRepository = new PostRepository();
        
        public ActionResult Index()
        {
            var posts = postRepository.RecentPosts(2);
            return View(posts);
        }

        public ActionResult About()
        {
            return View();
        }
    }
}
